From: Florian Müllner Date: Wed, 19 Feb 2020 00:43:23 +0000 (+0100) Subject: lookingGlass: Handle undefined in objectToString() X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~772^2^2~105 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=ff4623454;p=gnome-shell.git lookingGlass: Handle undefined in objectToString() Fallout from commit 9d941f8202: Template strings handle undefined values just fine, the replacement does not. Fix that. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1020 --- diff --git a/js/ui/lookingGlass.js b/js/ui/lookingGlass.js index d101591ef..54e3e4858 100644 --- a/js/ui/lookingGlass.js +++ b/js/ui/lookingGlass.js @@ -244,7 +244,7 @@ function objectToString(o) { // special case this since the default is way, way too verbose return ''; } else { - return o.toString(); + return o !== undefined ? o.toString() : 'undefined'; } }